# account是账户模块
import requests
from common.public import auth
from common.api_address import url_login


def login(account, password='Jc123123', client=5):
    # 手机号账号密码登录
    # 请求头
    headers = {
        "authorization": auth,
        "content-type": "application/json"
    }
    # 请求体
    uploads = {
        "account": account,
        "password": password,
        "client": client
    }
    response = requests.post(url=url_login, headers=headers, json=uploads)
    from common.util import write_log
    write_log('调用了login业务函数')
    return response


if __name__ == '__main__':
    response = login('19912312399')
    print(response.json())
